<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <title>建议使用信管帮APP</title>
    <link rel="icon" href="https://XGStudio2023.github.io/download/images/appstore1/Xlogo.webp">
    <link rel="stylesheet" href="../../css/header.css">
    <script>
        function ftj(){
        var _hmt = _hmt || [];
(function() {
  var hm = document.createElement("script");
  hm.src = "https://hm.baidu.com/hm.js?bf7c9dd09dc20e82b0fcb28872ddb927";
  var s = document.getElementsByTagName("script")[0]; 
  s.parentNode.insertBefore(hm, s);
})();
        }
        ftj()

</script>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        html,body{
            height: 100%;



            -webkit-user-select:none;
            -moz-user-select:none;
            -ms-user-select:none;
            user-select:none;
        }
        ul li{
            list-style: none;
        }
        ::-webkit-scrollbar{
            width: 0rem;
        }
        body{
            background: #f6f6f6a1;
            display: flex;
            flex-direction: column;
            
            
        }
        section{
            /*
            border: 1px solid red;*/

            
            /**/

            flex: 1;
            /*
            display: flex;
            justify-content: center;*/
            /*部分安卓真机header不显示
            min-height: fit-content;*/
            overflow-y: scroll;

        }
        .container .t{
            /*
            border: 1px solid red;*/
            margin-left: 5%;
            font-size: .3865rem;/*16px*/
            color: #929292;
        }
        .container .ul1{
            /*
            border: 1px solid red;*/
            border-radius: .1208rem;/*5px*/
            /*
            box-shadow: .2415rem .2415rem .2415rem rgb(190, 190, 190);
            */
            width: 90%;
            font-size: .3865rem;/*16px*/
            line-height: 1.087rem;/*45px*/
            margin: .2415rem auto;
        }
        .container .ul1 li{
            /*
            border: 1px solid red;*/
            height: 1.087rem;/*45px*/
            /*
            text-align: center;*/
            border-bottom: .0121rem solid rgba(185, 185, 185, 0.429);
        }
        /*
        .container .ul1 li:nth-child(even){
            background-color: #f2f2f2;
        }
        .container .ul1 li:nth-child(odd){
            background-color: #b3e7ff70;
        }*/
        .container .ul1 li:first-child{
            border-radius: .1208rem .1208rem 0 0;/*5px*/
        }
        .container .ul1 li:last-child{
            border-radius: 0 0 .1208rem .1208rem;/*5px*/
        }
        .ul1 li span:nth-child(1){
            /*
            border: 1px solid red;*/
            display: inline-block;
            width: .9662rem;
            color: #363636;
            margin-left: .2415rem;/*10px*/
        }
        .ul1 li span:nth-child(2){
            /*
            border: 1px solid rgb(0, 255, 81);*/
            display: inline-block;
            color: #46d633fa;
            
            letter-spacing: .0242rem;
            font-weight: 600;
        }
        textarea{
            box-sizing: border-box;
            border-radius: .1208rem;/*5px*/
            width: 90%;
            margin: .2415rem 5%;
            padding: .2415rem;
            
        }
        .copyBtn{
            width: 4.8309rem;/*200px*/
            height: 1.2077rem;/*50px*/
            border: none;
            border-radius: .6039rem;
            background: #4099ff;
            color: #fff;
            font-size: .4348rem;/*18px*/
            margin-left: 50%;
            margin-bottom: .9662rem;/*300*/
            transform: translateX(-2.4155rem);
            letter-spacing: .0483rem;
            
        }
        
        
    </style>
</head>
<body>
    <header>
        <div class="backBtn"></div>
        <div class="left"></div>
        <span class="title">作业3</span>
    </header>
    <script>
        document.querySelector(".backBtn").onclick=function(){
            ftj()
            window.history.go(-1)
        }
        /*
        document.querySelector(".right").onclick=function(){
            window.location.replace('./index.html')
        }*/
    </script>

    <section>
        <div class="container">
            <!-- 判断题 -->
            <span class="t t1">判断题</span>
            <br>
            <ul class="ul1">
                <li>
                    <span>1-1</span>
                    <span>F</span>
                </li>
                
                <li>
                    <span>1-2</span>
                    <span>F</span>
                </li>
                
                <li>
                    <span>1-3</span>
                    <span>T</span>
                </li>
                
                <li>
                    <span>1-4</span>
                    <span>F</span>
                </li>
                
                <li>
                    <span>1-5</span>
                    <span>T</span>
                </li>
                
                
                
            </ul>
            
            <!-- 单选题 -->
            <span class="t t1">单选题</span>
            <br>
            <ul class="ul1">
                <li>
                    <span>2-1</span>
                    <span>B</span>
                </li>
                
                <li>
                    <span>2-2</span>
                    <span>B</span>
                </li>
                
                <li>
                    <span>2-3</span>
                    <span>A</span>
                </li>
                
                <li>
                    <span>2-4</span>
                    <span>C</span>
                </li>
                
                <li>
                    <span>2-5</span>
                    <span>C</span>
                </li>
                
                
                
            </ul>
            






            <!-- 编程题 -->
            <span class="t t2">编程题</span>
            <br>
            <span class="t t2">7-1 计算火车运行时间</span>
            <br>
            <textarea name="" id="txt1" cols="30" rows="10">#include <stdio.h>
int main()
{
    int time1, time2;
    scanf("%d %d", &time1, &time2);
    int hour = time2/100 - time1/100;
    int minute = time2%100 - time1%100;
    if (minute < 0){
        minute += 60;
        hour--;
    }
    printf("%02d:%02d", hour, minute);
    return 0;
}</textarea>
            <br>
            <button id="copyBtn1" class="copyBtn" onclick="copy1()">一键复制</button>


            <!-- 复制 -->
            <script>
                function copy1() {
                    var element = document.getElementById("txt1");
                    var copyBtn = document.getElementById("copyBtn1");
                    element.select();
                    element.setSelectionRange(0, element.value.length);
                    document.execCommand('copy');
                    copyBtn.style.background='#c0c0c0'
                    copyBtn.innerHTML='已复制'
                    setTimeout(function(){
                        copyBtn.style.background='#4099ff'
                        copyBtn.innerHTML='一键复制'
                    },2000)
                }
            </script>


            <span class="t">7-3 逆序的三位数</span>
            <br>
            <textarea name="" id="txt2" cols="30" rows="10">#include <stdio.h>
int main()
{
    int a;
    scanf("%d", &a);
    printf("%d", (a%10)*100+((a/10)%10)*10+(a/100));
    return 0;
}</textarea>
            <br>
            <button id="copyBtn2" class="copyBtn" onclick="copy2()">一键复制</button>


            <!-- 复制 -->
            <script>
                function copy2() {
                    var element = document.getElementById("txt2");
                    var copyBtn = document.getElementById("copyBtn2");
                    element.select();
                    element.setSelectionRange(0, element.value.length);
                    document.execCommand('copy');
                    copyBtn.style.background='#c0c0c0'
                    copyBtn.innerHTML='已复制'
                    setTimeout(function(){
                        copyBtn.style.background='#4099ff'
                        copyBtn.innerHTML='一键复制'
                    },2000)
                }
            </script>
        </div>
    </section>
    






    
    <script>
        //根据设备宽度计算html的font-size
        function resetHtmlFont(){
            //获取html对象并动态设置font-size = 设备宽度的1/10
            document.documentElement.style.fontSize = screen.width/10 + 'px';
        }
        //执行一下
        resetHtmlFont();
        //如果窗口大小改变了，则重新计算基础font-size
        window.onresize = resetHtmlFont;
    </script>
</body>
</html>
